package com.naiterui.ehp.bs.agent.feign;

import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestParam;

import com.naiterui.ehp.bp.bo.agent.DoctorDetailBO;
import com.naiterui.ehp.bp.support.config.FeignConfiguration;
import com.naiterui.ehp.bp.support.exception.BusinessException;

/**
 * es搜索服务
 * 
 * @author yangfuya
 * @since 2022/2/16
 */
@FeignClient(name = "ad", url = "${ehp.domain.ad}", configuration = FeignConfiguration.class)
public interface IDoctorFeignClient {

    @GetMapping("/inner/doctor/getDetail")
    DoctorDetailBO getUserById(@RequestParam("doctorId") Long doctorId) throws BusinessException;

    /**
     * 验证身份证、姓名对应合法性
     *
     * @param idCard
     * @param name
     * @return
     * @throws BusinessException
     */
    @GetMapping("inner/doctor/idcard/verify")
    Void verifyIdCard(@RequestParam("idCard") String idCard, @RequestParam("name") String name)
        throws BusinessException;
}
